package com.heima.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.github.pagehelper.Page;
import com.heima.pojo.domain.Partner;
import com.heima.pojo.vo.PartnerVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface PartnerMapper extends BaseMapper<Partner> {


    public Page<Partner> selectList(String name);

    PartnerVo look(Integer id);

    int insertPartner(Partner partner);

    int delPartner(Integer id);

    int updatePartner(Integer id, String name, String contact, String mobile, Integer ratio, String account);

    @Select("select COUNT(*) from tb_partner")
    Integer countPartner();
}
